package com.cloudfun.campusshare.common.constant;

/**
 * Created by Huqin on 2020/8/10
 */
public enum BankType {
    TO_B("B", "对公"),
    TO_C("C", "对私");

    private final String value;
    private final String desc;

    BankType(String value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    public static BankType searchValue(String value){
        for (BankType bankType : BankType.values()) {
            if (value.equals(bankType.getValue())){
                return bankType;
            }
        }
        return null;
    }
    public String getValue() {
        return value;
    }

    public String getDesc() {
        return desc;
    }
}
